import request from '@/config/axios'

// 招生资格审查批次 VO
export interface ReviewBatchVO {
  id: string // 主键
  batchName: string // 批次名称
  year: string // 年度
  applyStartTime: Date // 申请开始时间
  applyEndTime: Date // 申请结束时间
  reviewStartTime: Date // 评审开始时间
  reviewEndTime: Date // 评审结束时间
  remark: string // 备注
}

// 招生资格审查批次 API
export const ReviewBatchApi = {
  // 查询招生资格审查批次分页
  getReviewBatchPage: async (params: any) => {
    return await request.get({ url: `/recruit/review-batch/list`, params })
  },

  // 查询招生资格审查批次详情
  getReviewBatch: async (id: number) => {
    return await request.get({ url: `/recruit/review-batch/get?id=` + id })
  },

  // 新增招生资格审查批次
  createReviewBatch: async (data: ReviewBatchVO) => {
    return await request.post({ url: `/recruit/review-batch/create`, data })
  },

  // 修改招生资格审查批次
  updateReviewBatch: async (data: ReviewBatchVO) => {
    return await request.put({ url: `/recruit/review-batch/update`, data })
  },

  // 删除招生资格审查批次
  deleteReviewBatch: async (id: number) => {
    return await request.delete({ url: `/recruit/review-batch/delete?id=` + id })
  },
}
